package keni.html.android.framework.util;

import java.util.ArrayList;
import java.util.List;


		public class GraphNode  implements IVertex
		{

			private List<GraphNode> outgoing;

			public void AddDependent(GraphNode node)
			{
				if (outgoing == null)
				{
					outgoing = new ArrayList<GraphNode>();
				}
				outgoing.add(node);
			}

			/// <summary>
			///   The nodes that this node depends on
			/// </summary>
			public GraphNode[] getDependents()
			{
				
					if (outgoing == null)
					{
						return new GraphNode[0];
					}
					return outgoing.toArray(new GraphNode[outgoing.size()]);
				
			}

			public IVertex[] getAdjacencies()
			{
				 return getDependents(); 
			}
		}
